package com.xbongbong.pro.smartsettings.pojo.dto;

import com.xbongbong.paas.toolbox.wrap.BaseDTO;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * @description: 业务下智能助手列表
 * @Author: hongxiao
 * @date: 2019-04-23 21:08
 * @since v1.0
 */
@Getter
@Setter
@ToString
public class SmartSettingsConditionValueDTO extends BaseDTO {
    /**
     * 业务类型
     * @see com.xbongbong.saas.enums.XbbRefTypeEnum
     */
    private Integer businessType;
    /**
     * saas或paas标识，1:saas,2:paas
     * @see com.xbongbong.pro.enums.SaasMarkEnum
     */
    @NotNull(message = "{dto.msg.smartSettingsConditionValue.saasMark.NotNull}")
    @Range(min = 1, max = 2, message = "{dto.msg.smartSettingsConditionValue.saasMark.Range}")
    private Integer saasMark;
    /**
     * 表单id
     */
    @NotNull(message = "{dto.msg.smartSettingsConditionValue.formId.NotNull}")
    private Long formId;
    /**
     * 别名
     */
    @NotBlank(message = "{dto.msg.smartSettingsConditionValue.attr.NotBlank}")
    private String attr;
    /**
     * 字段类型
     */
    @NotNull(message = "{dto.msg.smartSettingsConditionValue.fieldType.NotNull}")
    private Integer fieldType;
}
